import Vue from "vue"
import App from "./App.vue"
import router from "./router"
// import "../node_modules/bootstrap/dist/css/bootstrap.min.css"
import ElementUI from "element-ui"
import "element-ui/lib/theme-chalk/index.css"
Vue.use(ElementUI)
// import "./index.css"
import "./assets/css/index.css"
import axios from "axios"
import { Message } from "element-ui"
// 请求根路劲
axios.defaults.baseURL = "http://127.0.0.1:3000/api/"
axios.interceptors.request.use((config) => {
  config.headers.Authorization = window.sessionStorage.getItem("token")

  return config
})
Vue.prototype.$http = axios
Vue.prototype.$message = Message

Vue.config.productionTip = false

new Vue({
  render: (h) => h(App),
  router,
}).$mount("#app")
